import org from '../routes/org'
import system from '../routes/system'
import project from '../routes/project'
export default {
  path: '/',
  component: () => import(/* webpackChunkName: "credit-app" */ '@/cadmin/views/Layout.vue'),
  redirect: { name: 'cadmin_index' },
  meta: { root: true, title: '首页', org: ['org_credit_sys'] },
  children: [
    {
      path: 'cadmin',
      component: { render: h => h('router-view') },
      redirect: { name: 'cadmin_index' },
      meta: { icon: 'fa fa-fw fa-home', hidden: true },
      children: [
        {
          path: 'notice',
          name: 'cadmin_index',
          component: () =>
            import(/* webpackChunkName: "index" */ '@/cadmin/views/notice/Notice.vue'),
          meta: { title: '通知公告', icon: 'fa fa-fw fa-bullhorn', regionLevel: [1, 2] },
        },
        // {
        //   path: 'sing',
        //   component: () => import(/* webpackChunkName: "index" */ '@/cadmin/views/sing/Sing.vue'),
        //   meta: { title: '移动签到', icon: 'fa fa-fw fa-map-marker' },
        // },
        {
          path: 'log',
          component: () => import(/* webpackChunkName: "index" */ '@/cadmin/views/log/Log.vue'),
          meta: { title: '日志管理', icon: 'fa fa-fw fa-bookmark' },
        },
        {
          path: 'org',
          component: () =>
            import(/* webpackChunkName: "cadmin-org" */ '@/components/AliveView.vue'),
          meta: { title: '机构管理', icon: 'fa fa-fw fa-address-card-o' },
          children: org,
        },
        {
          path: 'project',
          component: { render: h => h('router-view') },
          meta: { title: '项目管理', icon: 'fa fa-fw fa-cog' },
          children: project,
        },
        {
          path: 'system',
          component: { render: h => h('router-view') },
          meta: { title: '系统配置', icon: 'fa fa-fw fa-cog' },
          children: system,
        },
        {
          path: 'seal',
          component: () =>
            import(/* webpackChunkName: "cadmin-org" */ '@/cadmin/views/seal/Index.vue'),
          meta: { title: '签章主体', icon: 'fa fa-fw fa-user' },
        },
      ],
    },
  ],
}
